package ooday02;

public class OverrideDemo {
    public static void main(String[] args) {
        //方法重写的测试类
        Student stu=new Student("软件工程", "2019001", "张三", 18, "北京");
        stu.sayHi();
        Teacher tae=new Teacher("张老师", 30, "北京", 1000);
        tae.sayHi();
        Doctor doc=new Doctor("李医生", 40, "北京", "主任");
        doc.sayHi();
    }
}
